The known personal digital electronic devices mostly use universal serial bus (Universal Serial Bus, USB) interface for data transmission. In general, the data is transferred to the USB device by the USB host. For the real-time data transmission and playback, data is damaged often due to the clock mismatch between the device and the host, resulting in errors. The clocks at the device must be synchronized with the clock at the host to maintain the correctness of data transmission.
To synchronize the USB device clock and the USB host clock, the traditional USB controller and the physical layer needs a clock meeting the specification of USB clock drifting to drive the digital circuit. Regardless of the use of external crystal oscillation or internal oscillation circuit, it is required to make the USB clock drifting to 500 ppm for high speed, and 2500 ppm for full speed. The simplest way is to use external crystal oscillation, but additional cost and PCB area will be used. On the other hand, extra calibration circuit and time will incur when using internal oscillation circuit.
The present invention provides a USB controller with automatic clock generation and method thereof, which can rapidly generate clocks required for the controller operation, and eliminate the use of external crystal oscillation and the internal oscillator calibration by synchronization and multiplexing signals, so as to satisfy USB specification, reduce production cost and reduce calibration time.